/**
 * Copyright (c) 2000-2011 Liferay, Inc. All rights reserved.
 *
 * This library is free software; you can redistribute it and/or modify it under
 * the terms of the GNU Lesser General Public License as published by the Free
 * Software Foundation; either version 2.1 of the License, or (at your option)
 * any later version.
 *
 * This library is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
 * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
 * details.
 */

package com.crossriver.crgis.database.service.persistence;

import com.crossriver.crgis.database.model.Application_C_of_O;

import com.liferay.portal.service.persistence.BasePersistence;

/**
 * The persistence interface for the application_ c_of_ o service.
 *
 * <p>
 * Never modify or reference this interface directly. Always use {@link Application_C_of_OUtil} to access the application_ c_of_ o persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface.
 * </p>
 *
 * <p>
 * Caching information and settings can be found in <code>portal.properties</code>
 * </p>
 *
 * @author Wole Adetiba
 * @see Application_C_of_OPersistenceImpl
 * @see Application_C_of_OUtil
 * @generated
 */
public interface Application_C_of_OPersistence extends BasePersistence<Application_C_of_O> {
	/**
	* Caches the application_ c_of_ o in the entity cache if it is enabled.
	*
	* @param application_C_of_O the application_ c_of_ o to cache
	*/
	public void cacheResult(
		com.crossriver.crgis.database.model.Application_C_of_O application_C_of_O);

	/**
	* Caches the application_ c_of_ os in the entity cache if it is enabled.
	*
	* @param application_C_of_Os the application_ c_of_ os to cache
	*/
	public void cacheResult(
		java.util.List<com.crossriver.crgis.database.model.Application_C_of_O> application_C_of_Os);

	/**
	* Creates a new application_ c_of_ o with the primary key. Does not add the application_ c_of_ o to the database.
	*
	* @param applicationId the primary key for the new application_ c_of_ o
	* @return the new application_ c_of_ o
	*/
	public com.crossriver.crgis.database.model.Application_C_of_O create(
		java.lang.String applicationId);

	/**
	* Removes the application_ c_of_ o with the primary key from the database. Also notifies the appropriate model listeners.
	*
	* @param applicationId the primary key of the application_ c_of_ o to remove
	* @return the application_ c_of_ o that was removed
	* @throws com.crossriver.crgis.database.NoSuchApplication_C_of_OException if a application_ c_of_ o with the primary key could not be found
	* @throws SystemException if a system exception occurred
	*/
	public com.crossriver.crgis.database.model.Application_C_of_O remove(
		java.lang.String applicationId)
		throws com.crossriver.crgis.database.NoSuchApplication_C_of_OException,
			com.liferay.portal.kernel.exception.SystemException;

	public com.crossriver.crgis.database.model.Application_C_of_O updateImpl(
		com.crossriver.crgis.database.model.Application_C_of_O application_C_of_O,
		boolean merge)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Finds the application_ c_of_ o with the primary key or throws a {@link com.crossriver.crgis.database.NoSuchApplication_C_of_OException} if it could not be found.
	*
	* @param applicationId the primary key of the application_ c_of_ o to find
	* @return the application_ c_of_ o
	* @throws com.crossriver.crgis.database.NoSuchApplication_C_of_OException if a application_ c_of_ o with the primary key could not be found
	* @throws SystemException if a system exception occurred
	*/
	public com.crossriver.crgis.database.model.Application_C_of_O findByPrimaryKey(
		java.lang.String applicationId)
		throws com.crossriver.crgis.database.NoSuchApplication_C_of_OException,
			com.liferay.portal.kernel.exception.SystemException;

	/**
	* Finds the application_ c_of_ o with the primary key or returns <code>null</code> if it could not be found.
	*
	* @param applicationId the primary key of the application_ c_of_ o to find
	* @return the application_ c_of_ o, or <code>null</code> if a application_ c_of_ o with the primary key could not be found
	* @throws SystemException if a system exception occurred
	*/
	public com.crossriver.crgis.database.model.Application_C_of_O fetchByPrimaryKey(
		java.lang.String applicationId)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Finds all the application_ c_of_ os where userId = &#63;.
	*
	* @param userId the user id to search with
	* @return the matching application_ c_of_ os
	* @throws SystemException if a system exception occurred
	*/
	public java.util.List<com.crossriver.crgis.database.model.Application_C_of_O> findByUserId(
		java.lang.String userId)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Finds a range of all the application_ c_of_ os where userId = &#63;.
	*
	* <p>
	* Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
	* </p>
	*
	* @param userId the user id to search with
	* @param start the lower bound of the range of application_ c_of_ os to return
	* @param end the upper bound of the range of application_ c_of_ os to return (not inclusive)
	* @return the range of matching application_ c_of_ os
	* @throws SystemException if a system exception occurred
	*/
	public java.util.List<com.crossriver.crgis.database.model.Application_C_of_O> findByUserId(
		java.lang.String userId, int start, int end)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Finds an ordered range of all the application_ c_of_ os where userId = &#63;.
	*
	* <p>
	* Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
	* </p>
	*
	* @param userId the user id to search with
	* @param start the lower bound of the range of application_ c_of_ os to return
	* @param end the upper bound of the range of application_ c_of_ os to return (not inclusive)
	* @param orderByComparator the comparator to order the results by
	* @return the ordered range of matching application_ c_of_ os
	* @throws SystemException if a system exception occurred
	*/
	public java.util.List<com.crossriver.crgis.database.model.Application_C_of_O> findByUserId(
		java.lang.String userId, int start, int end,
		com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Finds the first application_ c_of_ o in the ordered set where userId = &#63;.
	*
	* <p>
	* Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
	* </p>
	*
	* @param userId the user id to search with
	* @param orderByComparator the comparator to order the set by
	* @return the first matching application_ c_of_ o
	* @throws com.crossriver.crgis.database.NoSuchApplication_C_of_OException if a matching application_ c_of_ o could not be found
	* @throws SystemException if a system exception occurred
	*/
	public com.crossriver.crgis.database.model.Application_C_of_O findByUserId_First(
		java.lang.String userId,
		com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
		throws com.crossriver.crgis.database.NoSuchApplication_C_of_OException,
			com.liferay.portal.kernel.exception.SystemException;

	/**
	* Finds the last application_ c_of_ o in the ordered set where userId = &#63;.
	*
	* <p>
	* Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
	* </p>
	*
	* @param userId the user id to search with
	* @param orderByComparator the comparator to order the set by
	* @return the last matching application_ c_of_ o
	* @throws com.crossriver.crgis.database.NoSuchApplication_C_of_OException if a matching application_ c_of_ o could not be found
	* @throws SystemException if a system exception occurred
	*/
	public com.crossriver.crgis.database.model.Application_C_of_O findByUserId_Last(
		java.lang.String userId,
		com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
		throws com.crossriver.crgis.database.NoSuchApplication_C_of_OException,
			com.liferay.portal.kernel.exception.SystemException;

	/**
	* Finds the application_ c_of_ os before and after the current application_ c_of_ o in the ordered set where userId = &#63;.
	*
	* <p>
	* Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
	* </p>
	*
	* @param applicationId the primary key of the current application_ c_of_ o
	* @param userId the user id to search with
	* @param orderByComparator the comparator to order the set by
	* @return the previous, current, and next application_ c_of_ o
	* @throws com.crossriver.crgis.database.NoSuchApplication_C_of_OException if a application_ c_of_ o with the primary key could not be found
	* @throws SystemException if a system exception occurred
	*/
	public com.crossriver.crgis.database.model.Application_C_of_O[] findByUserId_PrevAndNext(
		java.lang.String applicationId, java.lang.String userId,
		com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
		throws com.crossriver.crgis.database.NoSuchApplication_C_of_OException,
			com.liferay.portal.kernel.exception.SystemException;

	/**
	* Finds all the application_ c_of_ os.
	*
	* @return the application_ c_of_ os
	* @throws SystemException if a system exception occurred
	*/
	public java.util.List<com.crossriver.crgis.database.model.Application_C_of_O> findAll()
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Finds a range of all the application_ c_of_ os.
	*
	* <p>
	* Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
	* </p>
	*
	* @param start the lower bound of the range of application_ c_of_ os to return
	* @param end the upper bound of the range of application_ c_of_ os to return (not inclusive)
	* @return the range of application_ c_of_ os
	* @throws SystemException if a system exception occurred
	*/
	public java.util.List<com.crossriver.crgis.database.model.Application_C_of_O> findAll(
		int start, int end)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Finds an ordered range of all the application_ c_of_ os.
	*
	* <p>
	* Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
	* </p>
	*
	* @param start the lower bound of the range of application_ c_of_ os to return
	* @param end the upper bound of the range of application_ c_of_ os to return (not inclusive)
	* @param orderByComparator the comparator to order the results by
	* @return the ordered range of application_ c_of_ os
	* @throws SystemException if a system exception occurred
	*/
	public java.util.List<com.crossriver.crgis.database.model.Application_C_of_O> findAll(
		int start, int end,
		com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Removes all the application_ c_of_ os where userId = &#63; from the database.
	*
	* @param userId the user id to search with
	* @throws SystemException if a system exception occurred
	*/
	public void removeByUserId(java.lang.String userId)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Removes all the application_ c_of_ os from the database.
	*
	* @throws SystemException if a system exception occurred
	*/
	public void removeAll()
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Counts all the application_ c_of_ os where userId = &#63;.
	*
	* @param userId the user id to search with
	* @return the number of matching application_ c_of_ os
	* @throws SystemException if a system exception occurred
	*/
	public int countByUserId(java.lang.String userId)
		throws com.liferay.portal.kernel.exception.SystemException;

	/**
	* Counts all the application_ c_of_ os.
	*
	* @return the number of application_ c_of_ os
	* @throws SystemException if a system exception occurred
	*/
	public int countAll()
		throws com.liferay.portal.kernel.exception.SystemException;
}